In battery-operated electrical systems, isolating the battery from an enclosure (e.g., the chassis of an electric vehicle) can prevent electric shock to service personnel who may accidentally contact the enclosure while working on the battery. Current systems for detecting the connection between the enclosure and the battery (also referred to herein as connection or ground faults) rely on complex circuits when direct current is used. Some of these circuits include voltage dividers positioned across the battery. The circuits determine that a ground fault is present based on the value of a voltage measured on the voltage divider. Further, these circuits can include comparators, switched capacitors, and other components to ensure stable operation in the presence of noise. The number and arrangement of components thus make ground fault detection systems expensive to manufacture.